function check_telephone() {
	var telephone = document.getElementById("telephone").value;
	var telreg = /^(13[0-9]|14[5|7]|15[0|1|2|3|5|6|7|8|9]|18[0|1|2|3|5|6|7|8|9])\d{8}$/;
	if (telephone == null || telephone == "") {
		$("#t_news").html("请输入您的手机号码");
		$("#t_news").css({"color":"red"});
		return false;
	}else if (!telreg.test(telephone))
	{
		$("#t_news").html("请输入正确的11位手机号码");
		$("#t_news").css({"color":"red"});
		return false;
	}else {
		$("#t_news").html("正确");
		$("#t_news").css({"color":"green"});
		return true;
	}
}
function check_mobile(){
	var mobile = document.getElementById("mobile").value;
	if (mobile == null || mobile == "") {
		$("#m_news").html("请输入短信动态码");
		$("#m_news").css({"color":"red"});
		return false;
	}
}
function check_password(){
	var password = document.getElementById("password").value;
	if (password == null || password == "") {
		$("#p_news").html("请填写密码");
		$("#p_news").css({"color":"red"});
		return false;
	}else if (password.length<6) {
		$("#p_news").html("密码太短，至少6个字符");
		$("#p_news").css({"color":"red"});
		return false;
	}else {
		$("#p_news").html("正确");
		$("#p_news").css({"color":"green"});
		return true;
	}
}
function check_repassword(){
	var password = document.getElementById("password").value;
	var repassword = document.getElementById("repassword").value;
	if (repassword == null || repassword == "") {
		$("#re_news").html("请再次输入密码");
		$("#re_news").css({"color":"red"});
		return false;
	}else if (password != repassword){
		$("#re_news").html("两次输入的密码不一致，请重新输入");
		$("#re_news").css({"color":"red"});
		return false;
	}else {
		$("#re_news").html("正确");
		$("#re_news").css({"color":"green"});
		return true;
	}
}
function CheckIntensity(pwd) {
	var Mcolor, Wcolor, Scolor;
	var m = 0;
	//匹配数字
	if (/\d+/.test(pwd)) {
		debugger;
		m++;
	};
	//匹配字母
	if (/[A-Za-z]+/.test(pwd)) {
		m++;
	};
	//匹配除数字字母外的特殊符号
	if (/[^0-9a-zA-Z]+/.test(pwd)) {
		m++;
	};

	if (pwd.length <= 6) { m = 1; }
	if (pwd.length <= 0) { m = 0; }
	switch (m) {
		case 1:
			Wcolor = "pwd pwd_Weak_c";
			Mcolor = "pwd pwd_c";
			Scolor = "pwd pwd_c pwd_c_r";
			break;
		case 2:
			Wcolor = "pwd pwd_Medium_c";
			Mcolor = "pwd pwd_Medium_c";
			Scolor = "pwd pwd_c pwd_c_r";
			break;
		case 3:
			Wcolor = "pwd pwd_Strong_c";
			Mcolor = "pwd pwd_Strong_c";
			Scolor = "pwd pwd_Strong_c pwd_Strong_c_r";
			break;
		default:
			Wcolor = "pwd pwd_c";
			Mcolor = "pwd pwd_c pwd_f";
			Scolor = "pwd pwd_c pwd_c_r";
			break;
	}
	document.getElementById('pwd_Weak').className = Wcolor;
	document.getElementById('pwd_Medium').className = Mcolor;
	document.getElementById('pwd_Strong').className = Scolor;
}